#!/bin/sh
#
# Start the networkscan....
#

case "$1" in
  start)
	echo "===== Starting networkscan ===== "
	#/sbin/ifup -a
	#[ $? = 0 ] && echo "OK" || echo "FAIL"
	cd /userapp/networkscan/
	/userapp/build_python/bin/python networkscan.py > log.txt 2>&1 &
	;;
  stop)
	echo "Stopping networkscan: "
	#/sbin/ifdown -a
	[ $? = 0 ] && echo "OK" || echo "FAIL"
	;;
  restart|reload)
	"$0" stop
	"$0" start
	;;
  *)
	echo "Usage: $0 {start|stop|restart}"
	exit 1
esac
exit 0

